#ifndef _RAY_H_
#define _RAY_H_

#include "Point3.h"
#include "Vector3.h"
#include "MathUtil.h"

#define EPSILON		0.0001

class Ray
{
public:
	Ray(void);
	Ray(Point3* o, Vector3* d);
	Ray(Point3* a, Point3* b);
	~Ray(void);


	double getMin();
	double getMax();
	Point3* getOrigin();
	Vector3* getDirection();
	bool isEmpty();
	bool isInside(double t);
	Point3* getPoint(double t, Point3* dest);
	void setMinMax(double min, double max);
	void setMin(double t);
	void setMax(double t);

private:
	Point3*		origin;
	Vector3*	direction;
	double		tMin;
	double		tMax;

};


#endif


